﻿using System;
using System.Collections.Generic;
using System.Diagnostics.Contracts;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Beaker.OpenCube.Render.Math
{
	public sealed class Matrix
	{
		private readonly double[,] _values;

		public Matrix()
			: this( null )
		{
		}

		public Matrix( double[,] values )
		{
			_values = new double[4, 4];
			
			if( values != null )
			{
				if( values.Length != 16 )
					throw new ArgumentException( "values" );
				if( values.GetUpperBound( 0 ) != 3 )
					throw new ArgumentException( "values" );
				if( values.GetUpperBound( 1 ) != 3 )
					throw new ArgumentException( "values" );

				Array.Copy( values, _values, 16 );
			}
		}

		[Pure]
		public double this[ int i1, int i2 ]
		{
			get { 
				if( i1 < 0 || i1 > 3 )
					throw new ArgumentOutOfRangeException("i1");
			}
		}

	)
			}
		}
	}
}
